<template>
    <div>
        <HeroSearch @sousuo="getValue"/>
        <HeroList :keyword="keyword"/>
    </div>
</template>

<script>
import HeroList from '@/components/HeroList.vue';
import HeroSearch from '@/components/HeroSearch.vue'; 
    export default {
        name: "Heros",
        data(){
            return{
                keyword:""
            }
        },
        components: {
            HeroList,
            HeroSearch
        },
        methods:{
            getValue(value){
                this.keyword=value
            }
        }
    }
</script>

<style scoped>

</style>